package com.school.basic.repository;

import com.school.basic.entity.ClassInfo;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public interface ClassInfoRepository extends JpaRepository<ClassInfo,Integer>, JpaSpecificationExecutor<ClassInfo> {
    void deleteClassInfosByIdIn(List<Integer> idList);
    boolean existsByClassNameAndGrade(String className,Integer grade);

    List<ClassInfo> findAllBySchoolId(Integer schoolId);
}
